package wuxianshua.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import wuxianshua.common.CommonRes;
import wuxianshua.pojo.Note;
import wuxianshua.service.NoteService;

import java.util.List;

/**
 * Description:
 * Datetime:    2021/3/25   21:07
 * Author:   jianglei
 */
@RestController
public class NoteController {

    @Autowired
    private NoteService noteService;

    @RequestMapping("/getnote")
    public CommonRes getNote(){
        List<Note> note = noteService.getNote();
        return  new CommonRes(0,"",note.size(),note);
    }
}